This invention relates to the processing of requests received in a selected packetized format, and more particularly to a method and apparatus for the accelerated processing of selected such requests, particularly hard real-time requests, such as those involved in industrial automation.
While there is always a desire for data processing requests to be processed quickly, response time, which is sometimes also referred to as turn-around time, is particularly critical for hard real-time applications, these being applications such as those in industrial automation where the processor is being utilized to control an ongoing process in real-time. For example, in an industrial automation process, a robot may have sensors which are scanned at frequent intervals, the sensor outputs being used to control a feedback process to the robot. It is frequently desirable that such processes operate with a turn-around time in the submillisecond range. However, while it is possible to obtain such processing speeds utilizing parallel processing techniques, supercomputers or other high cost devices, most hard real-time applications cannot justify the cost of such hardware and generally utilize PC""s or comparable hardware having turn-around times which are normally greater than one millisecond and, with even lower costs equipment, can be ten milliseconds or more.
A need therefore exists to permit low cost data processors, typically operating with turn-around times of one to ten milliseconds or more, to be able to perform selected hard real-time operations, particularly industrial automation applications, with turn-around times in the submillisecond range with little, if any, increase in hardware costs and with minimal software burden.
In accordance with the above, this invention provides a method and apparatus for permitting selected requests to a data processing system to be identified when received and to be handled in an expedited manner, eliminating certain steps in the operation not required for such requests and receiving processing priority. In particular, requests received in practicing the teachings of this invention are received in a packetized form, the packets being in accordance with a predetermined protocol which is preferably an Ethernet protocol. Each packet includes a field normally used for controlling routing of the request, which field is a xe2x80x9cportxe2x80x9d field for preferred embodiments. Selected codes in this field identify a request as a hard real-time or other request requiring rapid processing. A table is stored containing as a minimum, an entry for each of the selected codes and an address pointer to either a buffer containing a response to the packet or to an application stored in memory, which application is appropriate for processing the corresponding request. A routine (first routine) is also provided which compares the code in the given field, for example the port field, of an incoming request with codes stored in the table, passes requests with codes not in the table for normal processing and initiates an expedited processing, depending on the code, for requests having a code matching a code in the table. Where the pointer is to an address storing an application for processing the request, the first routine establishes a special process structure for the request, and routes such matching requests for priority processing by the application at the corresponding pointer address. Where the application causes a reply output to be generated, for example a feedback instruction to a robot or other machine used in an industrial automation application, the routine utilizes the special process structure to provide priority routing of a reply output to output circuitry. For example, where an Ethernet protocol is utilized for requests/replies and Ethernet routines have priority over other routines being run on the processor, first routines may be treated by the data processor as Ethernet routines. For such systems, the output circuitry would be an Ethernet driver. Where the address pointer is to a buffer containing information for a response to the request, the information at the pointer address is utilized to create a packetized reply.
One way in which requests afforded fast processing in accordance with the teachings of this invention may be processed approximately an order of magnitude faster than other requests applied to the system is that certain time consuming second processing routines normally performed on all requests are not required for the selected requests and are not performed. If a particular request requires one or more of these second processing routines, the request is either not routed for fast processing, or is routed for fast processing to perform a portion of the processing which may be expeditiously performed by the first routines to facilitate hard real-time operation and is also performed with the second routines for selected purposes.
A routine may also be provided for making an entry into the table, this xe2x80x9cregisterxe2x80x9d routine responding to an application request to store at least a selected code and address pointer. The register routine may also store selected flags for an entry. Finally, the apparatus may include a deregister routine which is operative for removing entries from the table.
The foregoing and other objects, features and advantages of the invention will be apparent from the following more particular description of preferred embodiments of the invention, as illustrated in the accompanying drawings.